import request from '@/utils/request'

// 员工导入--excel解析
export function excelAnalysis(data) {
  return request({
    url: `/v2/user/excel/analysis`,
    method: 'POST',
    data
  })
}

// 批量导入员工数据
export function batchImport(data) {
  return request({
    url: `/v2/user/excel/import`,
    method: 'POST',
    data
  })
}

export function getEntryList(data) {
  return request({
    url: `/v2/entry/information/list`,
    method: 'get',
    params: data
  })
}

export function getInterviewList(data) {
  return request({
    url: `/v2/entry/interview/see`,
    method: 'get',
    params: data
  })
}

// 入职与面试各类数据统计
export function entryOrInterviewData(data) {
  return request({
    url: '/v2/statistics/entry',
    method: 'GET',
    data
  })
}

export function getInterview(id) {
  return request({
    url: `/v2/entry/interview/see/${id}`,
    method: 'get'
  })
}

export function examineInterview(data) {
  return request({
    url: `/v2/entry/interview/examine`,
    method: 'post',
    data: data
  })
}

export function getEntry(id) {
  return request({
    url: `/v2/entry/information/${id}`,
    method: 'get'
  })
}

export function examineEntry(data) {
  return request({
    url: `/v2/entry/information/audit`,
    method: 'put',
    params: data
  })
}

// 设置表头生成excel
export function generateExcel(data) {
  return request({
    url: '/v2/user/excel/generate',
    method: 'POST',
    data
  })
}
